﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Sys.WebRes.Publish.Areas.Admin.Models
{
    public class SectionModel
    {
        public int ID { get; set; }
        public string Name { get; set; }
        public string Abbr { get; set; }
        public string Summary { get; set; }
        public int? ParentID { get; set; }
        public int? ResTypeID { get; set; }
        public int? StatusTypeID { get; set; }
        public int? LevelNo { get; set; }
        public int? OrderNo { get; set; }
        public bool Visible { get; set; }
        public bool DeletedFlag { get; set; }
        public List<SectionModel> children { get; set; }

        public string Text
        {
            get
            {
                return Name;
            }
        }

        public string Visible1 { 
            get 
            { 
                return Visible ? "1" : ""; 
            }
        }
        //public string name2 
        //{ 
        //    get { return string.Format("{0}:{1}", id, name); } 
        //}

        public SectionModel()
        {
            this.DeletedFlag = false;
            this.children = new List<SectionModel>();
        }
    }
}